Skip to content

Conversation

mwinkler
Copy link

@mwinkler mwinkler commented Sep 5, 2022

This change allow to optionally pass a HttpMessageHandler to the used HttpClient inside the logger.
Example:

var config = builder.Configuration.GetSection("Splunk").Get<SplunkLoggerConfiguration>();
var handler = new HttpClientHandler
{
     Proxy = new WebProxy("http://localhost:8080")
};
builder.Logging.AddProvider(new SplunkHECJsonLoggerProvider(config, null, handler));

To control, how the http client behaves and allows different use cases like adding a proxy, config ssl validation, ....

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant